﻿Namespace RemoteableObject

  ''' <summary>
  ''' Das IObserver Interface, definiert die Signatur der Methode, die der Server ausführt.
  ''' </summary>
  ''' <remarks></remarks>
  <System.Runtime.InteropServices.ComVisible(False)>
  Public Interface IObserver
    Function Authenticate(ByVal User As String, ByVal Pass As String) As String
    Function Revoke(ByVal Token As String) As Boolean
    Function SetValue(ByVal Token As String, ByVal Name As String, ByVal Value As String) As Auxiliary.EResult
    Function GetValue(ByVal Name As String) As String
    Function DelValue(ByVal Token As String, ByVal Name As String) As Auxiliary.EResult
    Function GetDB(ByVal Name As String, Optional ByVal CreateIfNotExist As Boolean = True) As String
    Function DeleteDB(ByVal Token As String, ByVal Name As String) As Auxiliary.EResult
    Function ListDBs(Optional ByVal Identifier As String = "") As List(Of String)
    Function ListValues(Optional ByVal Name As String = "") As Dictionary(Of String, String)
    Function ListPrivateValues(ByVal Identifier As Guid, Optional ByVal Name As String = "") As Dictionary(Of String, String)
    Function SetPrivateValue(ByVal Token As String, ByVal Identifier As Guid, ByVal Name As String, ByVal Value As String) As Auxiliary.EResult
    Function GetPrivateValue(ByVal Identifier As Guid, ByVal Name As String) As String
    Function DelPrivateValue(ByVal Token As String, ByVal Identifier As Guid, ByVal Name As String) As Auxiliary.EResult
    Property Result As Boolean
  End Interface
End Namespace